//
//  const.h
//  RXXKVideo
//
//  Created by 星仔 on 2019/3/17.
//  Copyright © 2019年 rxx. All rights reserved.
//

#ifndef const_h
#define const_h

#import <AFNetworking/AFNetworking.h>
#import <Masonry/Masonry.h>
#import <YYModel/YYModel.h>
#import <SDWebImage/UIImageView+WebCache.h>
#import <MJRefresh/MJRefresh.h>
#import "NSObject+YYModel.h"


#define RX_SCREEN_WIDTH   [UIScreen mainScreen].bounds.size.width
#define RX_SCREEN_HEIGHT  [UIScreen mainScreen].bounds.size.height

#define ScreenScale            RX_SCREEN_WIDTH / 750.0f
// 导航栏高度与tabbar高度
#define RX_NAVBAR_HEIGHT       (IS_iPhoneX ? 88.0f : 64.0f)
#define RX_TABBAR_HEIGHT       (IS_iPhoneX ? 83.0f : 49.0f)

// 状态栏高度
#define RX_STATUSBAR_HEIGHT    (IS_iPhoneX ? 44.0f : 20.0f)
#define RX_SAVEAREA_TOP         (IS_iPhoneX ? 24.0f : 0.0f)   // 顶部安全区域
// 判断是否是iPhone X系列
#define IS_iPhoneX      ([UIScreen instancesRespondToSelector:@selector(currentMode)] ?\
(\
CGSizeEqualToSize(CGSizeMake(375, 812),[UIScreen mainScreen].bounds.size)\
||\
CGSizeEqualToSize(CGSizeMake(812, 375),[UIScreen mainScreen].bounds.size)\
||\
CGSizeEqualToSize(CGSizeMake(414, 896),[UIScreen mainScreen].bounds.size)\
||\
CGSizeEqualToSize(CGSizeMake(896, 414),[UIScreen mainScreen].bounds.size))\
:\
NO)
#endif /* const_h */
